using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

using NBear.IoC.Service;

/// <summary>
/// Summary description for ServiceFactory
/// </summary>
public abstract class ServiceFactory
{
    private ServiceFactory()
    {
    }

    //description:

    //You should use standard castle component decleration schema to define service interface impls in Web.config
    //for more information about castle project and its IoC Configuration, 
    //please visit: http://www.castleproject.org/index.php/IoC:Configuration

    private static NBear.IoC.Service.ServiceFactory factory = NBear.IoC.Service.ServiceFactory.Create();

    public static IServiceInterfaceType GetService<IServiceInterfaceType>()
        where IServiceInterfaceType : IServiceInterface
    {
        return factory.GetService<IServiceInterfaceType>();
    }
}
